home *** CD-ROM | disk | FTP | other *** search
/ Cracking 2 / Cracking II..iso / Texty / crackme / Nullz Crackme 1.1 2-5.txt < prev    next >
Encoding:
Text File  |  1999-03-04  |  4.4 KB  |  116 lines

  1. Hello again...
  2.  
  3. I'm back with the second tut for the CrackMe by <<Nullz>>.
  4. This time it is the secong challenge we are looking at.
  5.  
  6. Taget    : CrackMe Version 1.1 (Registration Type: 2)
  7. Get it at: http://members.xoom.com/nullz/
  8. Tools    : Softice 3.0 or higher
  9.  
  10. As last time i wont describe the serial calculation routines,
  11. but only some hints to find the right serial. This is enough,
  12. when you want to catch serials for normal Shareware programs
  13. as well, but when you want to make keygens, you'll have to
  14. study the calculation routines.
  15.  
  16. Now, lets go on with the cracking part...:)
  17.  
  18. -Start by running the CrackMe.
  19.  Remember the first part...? We used GetDlgItemTextA to breake
  20.  on. So why not try it again ?
  21.  
  22. -Goto SoftIce by pushing Ctrl+d, and put a breakpoint on
  23.  GetDlgItemTextA (BPX GetDlgItemTextA)
  24.  
  25. -Write you name/Serial, I used EinZtein/7894561230.
  26.  
  27. -Press OK, and softice breaks...great! we are lucky :)
  28.  
  29. -Press F11 to get out of the CALL.
  30.  
  31. -Now check the EAX register, hmmm, mine showed EAX = 00000008.
  32.  (EinZtein = 8 chars), that must be the Name, and we are
  33.  interested in the Serial only, so press F5 to goto the next
  34.  GetDlgItemTextA Call.
  35.  
  36. -Ahh, now it is, EAX = 0000000A (7894561230 = 10 Chars(0Ah))
  37.  
  38. -We are in the right place now, so try to step a little by using F10.
  39.  
  40. -After a little stepping, you'll see a code looking some like this:
  41.  
  42. :00401B25 0FBE4C0414              movsx ecx, byte ptr [esp+eax+14] <--- Moves a Char from
  43. :00401B2A 03CF                    add ecx, edi                          your serial in to ECX
  44. :00401B2C 0FAFC8                  imul ecx, eax                    <--- Calculates the serial 
  45. :00401B2F 40                      inc eax 
  46. :00401B30 8BF9                    mov edi, ecx
  47. :00401B32 3BC6                    cmp eax, esi                     <--- is all the chars calculated ?
  48. :00401B34 76EF                    jbe 00401B25                     <--- No ? Start over
  49.  
  50. -This code is really not interesting if you're only fishing for the serial.
  51.  
  52. -So step by it until you'll come to a code looking like this:
  53.  
  54. :00401B3C 0FBE6C0C14              movsx ebp, byte ptr [esp+ecx+14] <--- Moves a Char from
  55. :00401B41 8BC7                    mov eax, edi                          your serial in to ECX
  56. :00401B43 33D2                    xor edx, edx                     
  57. :00401B45 F7F5                    div ebp                          
  58. :00401B47 33D2                    xor edx, edx                    
  59. :00401B49 BD0A000000              mov ebp, 0000000A
  60. :00401B4E F7F5                    div ebp
  61. :00401B50 80C230                  add dl, 30
  62. :00401B53 88540C48                mov byte ptr [esp+ecx+48], dl 
  63. :00401B57 41                      inc ecx
  64. :00401B58 3BCE                    cmp ecx, esi                     <--- All chars calculated ?
  65. :00401B5A 72E0                    jb 00401B3C                      <--- no ? Start over
  66.  
  67. -This piece of code is actually just an uninteresting as the first one, if you're only
  68.  fishing for the serial as we do now.
  69.  
  70. -Right after the shown code, this code will show up:
  71.  
  72. :00401B5C 8D542448                lea edx, dword ptr [esp+48]     <--- YOUR serial
  73. :00401B60 8D44247C                lea eax, dword ptr [esp+7C]     <--- CORRECT serial
  74. :00401B64 52                      push edx
  75. :00401B65 50                      push eax
  76.  
  77. * Reference To: KERNEL32.lstrcmpA, Ord:0295h
  78.                                   |
  79. :00401B66 FF1508404000            Call dword ptr [00404008]       <--- Compares serials
  80. :00401B6C 85C0                    test eax, eax                   <--- Correct serial ?
  81. :00401B6E 7550                    jne 00401BC0                    <--- If not.. Beat it
  82.  
  83. -ahh, dont that look familiar to you ?
  84.  
  85. -If you read the first tut, it should.
  86.  
  87. -We have here a compare routine, that should be easy to understand.
  88.  lstrcmpA = String Compare.
  89.  
  90. -So all you have to do, is: right after stepping pass 00401B64, type "D edx"
  91.  and "D eax", and you'll see both YOUR serial an the CORRECT serial.
  92.  
  93. -Write down the correct serial, Type "BD *", to disable the vreakpoint you might have set,
  94.  and press "Ctrl+D" to exit SoftIce.
  95.  
  96. -Now type your name and the correct serial in the textboxes, and BOOM, you passed.
  97.  Congratulations!
  98.  
  99. That's all for now, i hope you'd learned something...:)
  100.  
  101. Feel free to catch me on #efNet or mail me on einzteinius@hotmail.com, if you think anything 
  102. should be added, or something is wrong...
  103.  
  104. ...Enjoy!
  105.  
  106. /EinZtein
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.